cmake_minimum_required(VERSION 3.8)

set(CMAKE_SYSTEM_NAME iOS)
set(APP_NAME "oops-game-kit"  CACHE STRING "Project Name")

project(${APP_NAME} CXX)

set(CC_PROJECT_DIR ${CMAKE_CURRENT_LIST_DIR})
set(CC_UI_RESOURCES)
set(CC_PROJ_SOURCES)
set(CC_ASSET_FILES)
set(CC_COMMON_SOURCES)
set(CC_ALL_SOURCES)

include(${CC_PROJECT_DIR}/../common/CMakeLists.txt)

list(APPEND CC_PROJ_SOURCES
    ${CMAKE_CURRENT_LIST_DIR}/JsbBridgeTest.h
    ${CMAKE_CURRENT_LIST_DIR}/JsbBridgeTest.m

	${CMAKE_CURRENT_LIST_DIR}/ImagePicker.h
    ${CMAKE_CURRENT_LIST_DIR}/ImagePicker.m
)


set(EXECUTABLE_NAME ${APP_NAME}-mobile)

cc_ios_before_target(${EXECUTABLE_NAME})
add_executable(${EXECUTABLE_NAME} ${CC_ALL_SOURCES})

# 设置 Other Linker Flags
set_target_properties(${EXECUTABLE_NAME} PROPERTIES
    XCODE_ATTRIBUTE_OTHER_LDFLAGS "-ObjC -weak_framework Photos"
)

cc_ios_after_target(${EXECUTABLE_NAME})
